// init.c: The initial user-level program

char *argv[] = {"./busybox", "ls",  0};

#include "kernel/include/types.h"
#include "kernel/include/stat.h"
#include "kernel/include/file.h"
#include "kernel/include/fcntl.h"
#include "xv6-user/user.h"


int main(void)
{
  dev(O_RDWR, CONSOLE, 0);
  dup(0);  // stdout
  dup(0);  // stderr
  chdir("/");
  if (!fork()) {
    exec("./busybox", argv);
  }
  else {
    wait(0);
  }
  while(1);
}